<!DOCTYPE html>
<html>
	<head>
		<meta charset="utf-8">
		<title></title>
	</head>
	<body>
		<script type="text/javascript">
		    function createTable(row,col,width,height,bdcolor){
		        var tableStr="";
		        tableStr+=("<table style='width:"+width+"px;height:"+height+"px;border-collapse: collapse'>");
		        for(var i=0; i<row; i++){ 
		            tableStr+=("<tr>");
		            for(var j=0; j<col; j++){
		                tableStr+=("<td style='border:1px solid "+bdcolor+"'></td>");
		            }
		            tableStr+=("</tr>");
		        }
		        tableStr+=("</table>");
		        return tableStr;
		    }
		    document.write(createTable(4,6,500,160,"green"));
		</script>
	</body>
</html>
